public abstract class OrganizationComponent {
    private String name;
    private String desr;

    public OrganizationComponent(String name, String desr) {
        this.name = name;
        this.desr = desr;
    }

    protected void  add(OrganizationComponent organizationComponent){
        //默认实现(可重写也可不重写)
        throw new UnsupportedOperationException();
    }

    protected void  remove(OrganizationComponent organizationComponent){
        //默认实现(可重写也可不重写)
        throw new UnsupportedOperationException();
    }

    protected abstract void print();

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getDesr() {
        return desr;
    }

    public void setDesr(String desr) {
        this.desr = desr;
    }
}
